package com.yuanqi.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yuanqi.pojo.AttachmentTypeConfig;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 附件类型配置Mapper接口
 */
@Mapper
public interface AttachmentTypeConfigMapper extends BaseMapper<AttachmentTypeConfig> {
    
    /**
     * 根据状态查询附件类型配置
     */
    List<AttachmentTypeConfig> selectByStatus(@Param("status") Integer status);
    
    /**
     * 根据类型编码查询附件类型配置
     */
    AttachmentTypeConfig selectByTypeCode(@Param("typeCode") String typeCode);
    
    /**
     * 查询所有启用的附件类型配置（按排序顺序）
     */
    List<AttachmentTypeConfig> selectEnabledOrderBySort();
}
